package com.ruoyi.shop.domain;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * orders对象 orders
 *
 * @author ruoyi
 * @date 2025-06-10
 */
public class Orders extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 订单ID */
    private Long orderid;

    /** 订单编号 */
    @Excel(name = "订单编号")
    private String ordersn;

    /** 用户ID */
    @Excel(name = "用户ID")
    private Long userid;

    /** 收货地址 */
    @Excel(name = "收货地址")
    private Long receiveaddressid;

    /** 总价格 */
    @Excel(name = "总价格")
    private BigDecimal amount;

    /** 支付方式 */
    @Excel(name = "支付方式")
    private Long paytype;

    /** 状态 */
    @Excel(name = "状态")
    private Long state;

    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date createtime;



    /** 修改时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "修改时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date modifytime;

    /** 备注 */
    @Excel(name = "备注")
    private String note;

    /** 支付时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "支付时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date paytime;

    /** 发货时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "发货时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date deliverytime;

    /** 收货时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "收货时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date receivetime;

    public Date getCreatetime() {
        return createtime;
    }

    public void setCreatetime(Date createtime) {
        this.createtime = createtime;
    }
    private List<Orderdetail> orderdetailList;

    public List<Orderdetail> getOrderdetailList() {
        return orderdetailList;
    }

    public void setOrderdetailList(List<Orderdetail> orderdetailList) {
        this.orderdetailList = orderdetailList;
    }
    public void setOrderid(Long orderid)
    {
        this.orderid = orderid;
    }

    public Long getOrderid()
    {
        return orderid;
    }
    public void setOrdersn(String ordersn)
    {
        this.ordersn = ordersn;
    }

    public String getOrdersn()
    {
        return ordersn;
    }
    public void setUserid(Long userid)
    {
        this.userid = userid;
    }

    public Long getUserid()
    {
        return userid;
    }
    public void setReceiveaddressid(Long receiveaddressid)
    {
        this.receiveaddressid = receiveaddressid;
    }

    public Long getReceiveaddressid()
    {
        return receiveaddressid;
    }
    public void setAmount(BigDecimal amount)
    {
        this.amount = amount;
    }

    public BigDecimal getAmount()
    {
        return amount;
    }
    public void setPaytype(Long paytype)
    {
        this.paytype = paytype;
    }

    public Long getPaytype()
    {
        return paytype;
    }
    public void setState(Long state)
    {
        this.state = state;
    }

    public Long getState()
    {
        return state;
    }
    public void setModifytime(Date modifytime)
    {
        this.modifytime = modifytime;
    }

    public Date getModifytime()
    {
        return modifytime;
    }
    public void setNote(String note)
    {
        this.note = note;
    }

    public String getNote()
    {
        return note;
    }
    public void setPaytime(Date paytime)
    {
        this.paytime = paytime;
    }

    public Date getPaytime()
    {
        return paytime;
    }
    public void setDeliverytime(Date deliverytime)
    {
        this.deliverytime = deliverytime;
    }

    public Date getDeliverytime()
    {
        return deliverytime;
    }
    public void setReceivetime(Date receivetime)
    {
        this.receivetime = receivetime;
    }

    public Date getReceivetime()
    {
        return receivetime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("orderid", getOrderid())
            .append("ordersn", getOrdersn())
            .append("userid", getUserid())
            .append("receiveaddressid", getReceiveaddressid())
            .append("amount", getAmount())
            .append("paytype", getPaytype())
            .append("state", getState())
            .append("createtime", getCreatetime())
            .append("modifytime", getModifytime())
            .append("note", getNote())
            .append("paytime", getPaytime())
            .append("deliverytime", getDeliverytime())
            .append("receivetime", getReceivetime())
            .toString();
    }
}
